package com.iflytek.uoamp.notify.core.protocol;

import java.util.List;

import com.iflytek.uoamp.common.notify.obj.Contact;
import com.thoughtworks.xstream.annotations.XStreamAlias;
import com.thoughtworks.xstream.annotations.XStreamAsAttribute;
import com.thoughtworks.xstream.annotations.XStreamImplicit;

/**
 * DumpInfo中继承的contacts表示的是发送告警内容失败的联系人信息
 *
 */
@XStreamAlias("info")
public class DumpInfo{
    @XStreamAlias("retry")
    @XStreamAsAttribute
    private int retryCounts;
    
    @XStreamAlias("content")
    private String content;
    
    @XStreamAlias("pluginType")
    private String pluginType;
    
    @XStreamAlias("contacts")
    @XStreamImplicit(itemFieldName = "contacts")
    private List<Contact> contacts;

	public DumpInfo(List<Contact> contacts, String content, String pluginType) {
		this.contacts = contacts;
		this.content = content;
		this.pluginType = pluginType;
		this.retryCounts = 0;
	}
	
	public int getRetryCounts() {
		return retryCounts;
	}

	public void setRetryCounts(int retryCounts) {
		this.retryCounts = retryCounts;
	}
    
    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public List<Contact> getContacts() {
        return contacts;
    }
    public void setContacts(List<Contact> contacts) {
        this.contacts = contacts;
    }

    public String getPluginType() {
        return pluginType;
    }

    public void setPluginType(String pluginType) {
        this.pluginType = pluginType;
    }
}
